package com.situ.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.situ.model.Cart;
import com.situ.model.OrderItem;

import java.util.List;

public interface OrderItemService {
    //查询所有
    Page<OrderItem> findAll(Page<OrderItem> page, OrderItem orderItem);

    //查询某一个订单的订单项
    Page<OrderItem> findByOrderId(Page<OrderItem> page, Integer orderId);

    //删除订单项
    Integer deleteOrderItem(List<Integer> ids);

    //修改订单项
    boolean updateOrderItem(OrderItem orderItem);

    //创建订单项
    boolean createOrderItem(List<Cart> carts);

    //创建秒杀订单项
    boolean createSeckillOrderItem(OrderItem orderItem);

}
